Cross-chain: ICTT users index, bridged tokens tab, and stats layout#3351
Cross-chain: ICTT users index, bridged tokens tab, and stats layout#3351
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. To trigger a review, include ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
cursor review |
There was a problem hiding this comment.
Pull request overview
This PR introduces cross-chain UI/API integrations (ICTT users index and bridged tokens), extends interchain-indexer API resources, and refactors the stats/charts system to a new unified chart toolkit (line + sankey) with updated stats page layouts and navigation/metadata updates.
Changes:
- Add an ICTT users index page backed by the interchain indexer (routing, nav, metadata, UI table/list).
- Refactor Tokens into query hooks + sorting collection and add bridged tokens querying/sorting support.
- Replace legacy stats UI with client/features/chain-stats pages/hooks and a revamped chart toolkit (LineChart + SankeyChart widgets/menus/modals, CSV/PNG/share).
Reviewed changes
Copilot reviewed 144 out of 164 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| ui/tokens/utils.ts | Add Chakra createListCollection sort collection + bridged chains filter helper. |
| ui/tokens/useTokensQuery.ts | New hook for tokens list with filters/sorting/pagination. |
| ui/tokens/useBridgedTokensQuery.ts | New hook for bridged tokens list with filters/sorting/pagination. |
| ui/tokens/TokensTable.tsx | Align sorting handler type to Select OnValueChangeHandler. |
| ui/tokens/TokensActionBar.tsx | Remove legacy tokens action bar component. |
| ui/tokens/Tokens.tsx | Adjust action bar wiring and sorting handler type. |
| ui/shared/externalChains/ChainSnippetList.tsx | New reusable chain snippet renderer (icon/name/id + copy). |
| ui/shared/externalChains/ChainSelect.tsx | Add controlled multi-select “All chains” handling + multi label config. |
| ui/shared/chart/utils.ts | Switch comparator types to new line chart item types. |
| ui/shared/chart/useChartQuery.tsx | Remove legacy stats line chart query hook. |
| ui/shared/chart/config.ts | Switch chart config types to new line chart types. |
| ui/shared/chart/ChartWidget.pwstory.tsx | Update PW story to use LineChartWidget. |
| ui/shared/chart/ChartWidget.pw.tsx | Update PW tests prop types to new line chart widget props. |
| ui/shared/Page/PageTitle.tsx | Allow styling overrides for the second row via secondRowProps. |
| ui/pages/screenshots/Chart.pw.tsx_mobile_base-view-dark-mode-mobile-1.png | Update chart screenshot artifact. |
| ui/pages/screenshots/Chart.pw.tsx_default_base-view-dark-mode-mobile-1.png | Update chart screenshot artifact. |
| ui/pages/screenshots/Chart.pw.tsx_dark-color-mode_base-view-dark-mode-mobile-1.png | Update chart screenshot artifact. |
| ui/pages/Stats.tsx | Remove legacy stats index page implementation. |
| ui/pages/GasTracker.pw.tsx | Update mocks + selector names for new chart rendering. |
| ui/pages/Chart.pw.tsx | Remove legacy chart page PW test. |
| ui/multichain/stats/MultichainStats.tsx | Switch multichain stats page to useChainStats + new sections/filters/counters components. |
| ui/multichain/ecosystems/MultichainEcosystemsTableItem.tsx | Reuse new ChainSnippetList in ecosystems table row. |
| ui/multichain/ecosystems/MultichainEcosystemsListItem.tsx | Reuse new ChainSnippetList in mobile list row. |
| ui/megaEth/uptime/UptimeCharts.tsx | Migrate uptime charts to LineChartWidget and new axes config types. |
| ui/home/indicators/utils/chart.ts | Migrate homepage indicator chart typing to new line chart types. |
| ui/home/indicators/useChartDataQuery.tsx | Update hook return type to LineChartData. |
| ui/home/indicators/ChainIndicatorChartContent.tsx | Migrate indicator chart rendering to new line chart primitives/controllers. |
| ui/home/indicators/ChainIndicatorChartContainer.tsx | Update indicator chart container typing to new line chart types. |
| ui/gasTracker/GasTrackerChart.tsx | Use chain-stats chart container + new stubs, rename loading prop. |
| ui/address/coinBalance/AddressCoinBalanceChart.tsx | Replace legacy widget import with LineChartWidget. |
| types/client/stats.ts | Remove legacy stats interval types (moved to chain-stats feature). |
| types/api/interchainIndexer.ts | Remove local interchain indexer filter types (moved into cross-chain feature). |
| toolkit/utils/file.ts | Simplify CSV export helper signature to accept a single 2D array. |
| toolkit/components/charts/types.tsx | Remove old monolithic chart types module. |
| toolkit/components/charts/types.ts | Introduce new shared chart primitives + ChartResolution enum. |
| toolkit/components/charts/sankey/useSankeyController.ts | Rename sankey types/constants + fix import paths to new structure. |
| toolkit/components/charts/sankey/types.ts | Rename sankey exported types (SankeyChart*). |
| toolkit/components/charts/sankey/parts/SankeyChartNode.tsx | Rename component/types, adjust fallback rendering and tooltip formatting. |
| toolkit/components/charts/sankey/parts/SankeyChartMenu.tsx | Add CSV/fullscreen/share menu integration for sankey charts. |
| toolkit/components/charts/sankey/parts/SankeyChartLink.tsx | Rename component/types and format tooltip values. |
| toolkit/components/charts/sankey/index.ts | Update exports to new sankey component names. |
| toolkit/components/charts/sankey/constants.ts | Rename sankey default constant names. |
| toolkit/components/charts/sankey/SankeyChartWidget.tsx | New sankey widget wrapper with header/menu/content. |
| toolkit/components/charts/sankey/SankeyChartModal.tsx | New fullscreen modal for sankey charts. |
| toolkit/components/charts/sankey/SankeyChartContent.tsx | New shared content wrapper usage for sankey chart. |
| toolkit/components/charts/sankey/SankeyChart.tsx | Update to new types/constants + locale formatting and margin changes. |
| toolkit/components/charts/line/utils/useLineChartZoom.tsx | Rename zoom hook for line charts. |
| toolkit/components/charts/line/utils/useLineChartLegend.tsx | Rename legend hook for line charts. |
| toolkit/components/charts/line/utils/useLineChartController.tsx | Rename controller and update imports to new chart primitives. |
| toolkit/components/charts/line/utils/useLineChartBrushX.tsx | Rename brush hook and update import paths. |
| toolkit/components/charts/line/utils/lineChartAxis.ts | Rename axis config types and update import paths. |
| toolkit/components/charts/line/utils/getDateLabel.ts | Switch to shared ChartResolution. |
| toolkit/components/charts/line/utils/formatters.ts | Switch to new LineChartItem type. |
| toolkit/components/charts/line/utils/animations.ts | New line chart animation helpers (left/fade/none). |
| toolkit/components/charts/line/types.tsx | New line-chart-specific types module. |
| toolkit/components/charts/line/parts/tooltip/utils.ts | Add tooltip layout constants/helpers. |
| toolkit/components/charts/line/parts/tooltip/pointerTracker.ts | New pointer tracking helper for tooltip interactions. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipTitle.tsx | Rename/refactor tooltip title rendering for line charts. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipRow.tsx | Rename/refactor tooltip rows and DOM selectors. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipPoint.tsx | Rename/refactor tooltip point rendering and selectors. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipLine.tsx | Rename/refactor tooltip vertical line and selector. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipContent.tsx | Rename/refactor tooltip content wrapper and selector. |
| toolkit/components/charts/line/parts/tooltip/LineChartTooltipBackdrop.tsx | Rename/refactor tooltip backdrop wrapper and selector. |
| toolkit/components/charts/line/parts/LineChartTooltip.tsx | Rename/refactor tooltip assembly to new components/resolution type. |
| toolkit/components/charts/line/parts/LineChartSelectionX.tsx | Rename/refactor brush selection and selectors. |
| toolkit/components/charts/line/parts/LineChartOverlay.tsx | Rename overlay component type. |
| toolkit/components/charts/line/parts/LineChartMenu.tsx | New menu wrapper (csv/fullscreen/share) for line charts. |
| toolkit/components/charts/line/parts/LineChartLine.tsx | Rename line component and update types/animation usage. |
| toolkit/components/charts/line/parts/LineChartLegend.tsx | Rename legend component and update types. |
| toolkit/components/charts/line/parts/LineChartGridLine.tsx | Rename grid line component props/type. |
| toolkit/components/charts/line/parts/LineChartAxis.tsx | Rename axis component props/type and fix import paths. |
| toolkit/components/charts/line/parts/LineChartArea.tsx | Rename area component props/type and fix types. |
| toolkit/components/charts/line/index.ts | New barrel exports for line chart toolkit. |
| toolkit/components/charts/line/LineChartWidget.tsx | New line chart widget (legend, zoom reset, menu, content). |
| toolkit/components/charts/line/LineChartModal.tsx | New fullscreen modal for line charts. |
| toolkit/components/charts/line/LineChartContent.tsx | New shared content wrapper usage for line charts. |
| toolkit/components/charts/line/LineChart.tsx | Rename/refactor chart root to LineChart and new sub-components. |
| toolkit/components/charts/index.ts | Switch to exporting new components, line, and sankey modules. |
| toolkit/components/charts/components/index.ts | New barrel for shared chart UI components. |
| toolkit/components/charts/components/ChartWidget.tsx | New shared widget root/header components. |
| toolkit/components/charts/components/ChartWatermark.tsx | New shared chart watermark component. |
| toolkit/components/charts/components/ChartResetZoomButton.tsx | New shared zoom reset button component. |
| toolkit/components/charts/components/ChartMenu.tsx | New shared chart menu (share/copy, fullscreen, png, csv). |
| toolkit/components/charts/components/ChartDialog.tsx | New shared dialog wrapper for fullscreen charts. |
| toolkit/components/charts/components/ChartContent.tsx | New shared content state handler (loading/error/empty/watermark). |
| toolkit/components/charts/ChartWidgetContent.tsx | Remove legacy chart widget content wrapper. |
| toolkit/components/charts/ChartWidget.tsx | Remove legacy chart widget implementation. |
| toolkit/components/charts/ChartFullscreenDialog.tsx | Remove legacy fullscreen chart dialog. |
| toolkit/chakra/select.tsx | Add OnValueChangeHandler type + multi-select value text display config. |
| stubs/tx.ts | Migrate stats counters stub usage to chain-stats stubs. |
| stubs/stats.ts | Remove legacy stats stubs and switch to chain-stats stubs. |
| stubs/interchainIndexer.ts | Extend interchain indexer stubs for chains stats + bridged tokens. |
| stubs/contract.ts | Migrate verified contracts counters stub usage to chain-stats stubs. |
| public/icons/name.d.ts | Add navigation icon name for ICTT users. |
| pnpm-lock.yaml | Bump interchain-indexer-types and add d3-transition deps. |
| pages/stats/index.tsx | Route stats index to ChainStatsIndex (or MultichainStats). |
| pages/stats/[id].tsx | Route stats details to ChainStatsDetails (dynamic, ssr:false). |
| pages/ictt-users.tsx | New ICTT users route page. |
| package.json | Bump interchain-indexer-types + add d3-transition dependencies. |
| nextjs/nextjs-routes.d.ts | Add /ictt-users route typing. |
| mocks/stats/main.tsx | Update stats mocks import path to new chain-stats mocks. |
| mocks/multichain/stats.ts | Update multichain stats mocks import path to chain-stats mocks. |
| lib/router/useQueryParams.ts | Allow array values in updateQuery. |
| lib/mixpanel/getPageType.ts | Add page type mapping for /ictt-users. |
| lib/metadata/templates/title.ts | Add title template for /ictt-users. |
| lib/metadata/templates/description.ts | Add description template for /ictt-users. |
| lib/metadata/getPageOgType.ts | Add OG type mapping for /ictt-users. |
| lib/hooks/useNavItems.tsx | Add nav entry for ICTT users. |
| lib/api/services/interchainIndexer.ts | Add new interchain indexer resources (chains, stats, bridged tokens, message paths) + sorting types. |
| lib/api/resources.ts | Wire interchain indexer pagination sorting into shared resource typing. |
| icons/navigation/ictt_users.svg | Add new navigation icon asset. |
| docs/ENVS.md | Update example interchain indexer host URL. |
| configs/envs/.env.numine | Enable cross-chain txs + set new indexer host; add alerts content. |
| client/features/cross-chain-txs/utils/ictt-sort.ts | Add ICTT users sorting options/sequence. |
| client/features/cross-chain-txs/utils/chain-stats.ts | Define cross-chain charts/sections for stats integration. |
| client/features/cross-chain-txs/utils/bridged-tokens-sort.ts | Add bridged tokens sorting options/sequence + collection. |
| client/features/cross-chain-txs/types/api.ts | Add cross-chain filters + sorting types. |
| client/features/cross-chain-txs/stubs/chain-stats.ts | Add stub payload for cross-chain sankey charts. |
| client/features/cross-chain-txs/pages/ictt-users/IcttUsersTableItem.tsx | New ICTT users table row component. |
| client/features/cross-chain-txs/pages/ictt-users/IcttUsersTable.tsx | New ICTT users table with sortable columns. |
| client/features/cross-chain-txs/pages/ictt-users/IcttUsersListItem.tsx | New ICTT users mobile list item. |
| client/features/cross-chain-txs/pages/ictt-users/IcttUsers.tsx | New ICTT users page with sort + pagination. |
| client/features/cross-chain-txs/pages/bridged-tokens/BridgedTokensTableItem.tsx | New bridged tokens table row (token entity/address). |
| client/features/cross-chain-txs/pages/bridged-tokens/BridgedTokensTable.tsx | New bridged tokens table with sortable metrics. |
| client/features/cross-chain-txs/pages/bridged-tokens/BridgedTokensListItem.tsx | New bridged tokens mobile list item. |
| client/features/cross-chain-txs/pages/bridged-tokens/BridgedTokensIndex.tsx | Bridged tokens list/table wrapper for tokens tab. |
| client/features/cross-chain-txs/hooks/useCrossChainChartQuery.ts | New query hook building sankey data from message paths API. |
| client/features/cross-chain-txs/hooks/useBridgedTokensQuery.ts | New query hook for bridged tokens (filters/sorting/pagination). |
| client/features/cross-chain-txs/components/ChartWidgetContainerCrossChain.tsx | Sankey chart widget container for stats sections integration. |
| client/features/cross-chain-txs/components/ChainStatsDetailsCrossChainTxs.tsx | Cross-chain stats details view with chain filter + sankey + menu. |
| client/features/chain-stats/utils/resolution.ts | Parse resolution from query to chart resolution enum. |
| client/features/chain-stats/utils/interval.ts | Stats interval constants + date range helpers + query parsing. |
| client/features/chain-stats/utils/chart.ts | Helper to build absolute chart URLs. |
| client/features/chain-stats/types/client.ts | New chain-stats feature types (sections, chart payloads, intervals). |
| client/features/chain-stats/stubs/counters.ts | New stub counter payload for placeholders. |
| client/features/chain-stats/stubs/charts.ts | New stub charts/sections payload for placeholders. |
| client/features/chain-stats/pages/index/ChainStatsSections.tsx | New stats sections list (line + cross-chain sankey integration). |
| client/features/chain-stats/pages/index/ChainStatsIndex.tsx | New stats index page composing title/counters/filters/sections. |
| client/features/chain-stats/pages/index/ChainStatsFilters.tsx | New filters component (section select, interval select, search). |
| client/features/chain-stats/pages/index/ChainStatsErrorAlert.tsx | Rename alert component for chain-stats context. |
| client/features/chain-stats/pages/index/ChainStatsCounters.tsx | Fix counters grid layout + use new placeholder stubs. |
| client/features/chain-stats/pages/details/ChainStatsDetails.tsx | New stats details page deciding between line vs cross-chain sankey. |
| client/features/chain-stats/pages/details/ChainStatsDetails.pw.tsx | New PW coverage for stats details including cross-chain view. |
| client/features/chain-stats/mocks/lines.ts | New mocks for stats sections/charts list. |
| client/features/chain-stats/mocks/cross-chain-txs-paths.ts | New mocks for cross-chain message paths. |
| client/features/chain-stats/hooks/useChartQuery.tsx | New line-chart query hook returning normalized line payload. |
| client/features/chain-stats/hooks/useChainStats.tsx | New stats index hook merging cross-chain sections when enabled. |
| client/features/chain-stats/components/ChartWidgetContainer.tsx | New line chart widget container for stats index tiles. |
| client/features/chain-stats/components/ChartIntervalSelect.tsx | New interval select wired to chain-stats interval constants. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
… and change chart sorting to ascending order
Description and Related Issue(s)
This pull request adds cross-chain–related UI and API integration for the work tracked in #3314. It introduces an ICTT users index page backed by the interchain indexer, integrates bridged tokens as a tab on the main Tokens page (with dedicated token and bridged-token query hooks), the new charts for cross-chain messages statistics, and fixes the layout of statistics counters on the stats page. Navigation, metadata, and multichain ecosystem list presentation are updated to support these flows.
Related to #3314.
Proposed Changes
ictt-userspage, navigation entry, and interchain indexer client/stub extensions to load and display ICTT user data.useTokensQueryanduseBridgedTokensQuery; remove the superseded tokens action bar pattern in favor of the new structure.PageTitle,ChainSnippetList, ecosystem table/list items, routing types, and related metadata or tracking hooks where the new routes require them.No environment variables were added or changed in this pull request.
Breaking or Incompatible Changes
None.
Checklist for PR author